//
//  HttpRequestHelper.h
//  MengCP
//
//  Created by Gideon on 16/4/27.
//  Copyright © 2016年 LiZhenning. All rights reserved.
//


#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>

@class UserModel,
NewsIndexModel,
CommentIndexModel,
ConfigureModel,
HomeSliderModel,
TeacherIndexModel,
ConfigSignupFormTipsModel
;

@interface HttpRequestHelper : NSObject


//http://api.38ch.com/api/server/info?app_ver=1.04


/**
 获取网络请求地址

 @param app_ver
 */
+ (void)requestApiServerInfoApp_ver:(NSString *)app_ver Block:(void(^)(NSString *msg))block;


/**
 获取验证码
 
 @param mobile 手机号
 @param check 核对是否存在手机号
 @param block
 */
+(void)requestApiAuthCodeMobile:(NSString *)mobile check:(NSInteger)check Block:(void(^)(NSString *code, NSString *msg))block;



/**
 注册
 
 @param mobile 手机号
 @param nickname 昵称
 @param vcode 验证码
 @param block
 */
+(void)requestApiRegisterMobile:(NSString *)mobile
                       nickname:(NSString *)nickname
                       password:(NSString *)password
                          vcode:(NSString * )vcode
                          Block:(void(^)(NSString *msg,NSString * infoMsg))block;



/**
 登录
 
 @param mobile 手机号
 @param password 密码
 @param type 类型
 @param vcode 验证码
 @param block
 */
+(void)requestApiLoginMobile:(NSString *)mobile
                    password:(NSString *)password
                        type:(NSString *)type
                       vcode:(NSString * )vcode
                       Block:(void(^)(NSString *msg,NSString * infoMsg,UserModel * model))block;



/**
 忘记密码
 
 @param mobile 手机号
 @param repassword 重输入密码
 @param password 密码
 @param vcode 验证码
 @param block
 */
+(void)requestApiLoginChpwdMobile:(NSString *)mobile
                       repassword:(NSString *)repassword
                         password:(NSString *)password
                            vcode:(NSString * )vcode
                            Block:(void(^)(NSString *msg,NSString * infoMsg))block;



/**
 退出登录
 
 @param block
 */
+(void)requestApiLogoutBlock:(void(^)(NSString *msg))block;




/**
 修改资料
 
 @param intro 简介
 @param nickname 昵称
 @param addr 地址详情
 @param area 区域
 @param avatar 头像
 @param mobile 手机号
 @param block
 */
+(void)requestApiUserEditIntro:(NSString *)intro
                      nickname:(NSString *)nickname
                          addr:(NSString *)addr
                          area:(NSString *)area
                        avatar:(UIImage *)avatar
                        mobile:(NSString *)mobile
                         Block:(void(^)(NSString *msg,UserModel * model))block;



/**
 内容列表
 
 @param type
 @param page
 @param nums
 @param block
 */
+(void)requestApiNewsType:(NSInteger)type
                     page:(NSInteger)page
                     nums:(NSInteger)nums
                    Block:(void(^)(NSString *msg,NSArray * array))block;



/**
 文章详情
 
 @param Id
 @param block
 */
+(void)requestApiNewsDetailsId:(NSString *)Id
                         Block:(void(^)(NSString *msg,NewsIndexModel * model))block;



/**
 发起评论
 
 @param msg
 @param news_id
 @param block
 */
+(void)requestApiCommentAddMsg:(NSString *)msg
                       news_id:(NSString *)news_id
                         Block:(void(^)(NSString *msg,NSString * infoMsg))block;


/**
 评论点赞
 
 @param opt
 @param comment_id
 @param block
 */
+(void)requestApiCommentOpt:(NSString *)opt
                 comment_id:(NSString *)comment_id
                      Block:(void(^)(NSString *msg))block;



/**
 评论列表
 
 @param page
 @param nums
 @param news_id
 @param block
 */
+(void)requestApiCommentPage:(NSInteger)page
                        nums:(NSInteger)nums
                     news_id:(NSString *)news_id
                       Block:(void(^)(NSString *msg,NSArray * array))block;




/**
 意见反馈
 
 @param mobile 手机号
 @param msg 内容
 @param block
 */
+(void)requestApiFeedbackMobile:(NSString *)mobile
                            msg:(NSString *)msg
                          Block:(void(^)(NSString *msg))block;



/**
 获取配置信息
 
 @param block
 */
+(void)requestApiConfigureBlock:(void(^)(NSString *msg,ConfigureModel * model))block;



/**
 幻灯
 
 @param nums
 @param block
 */
+(void)requestApiBannerNums:(NSInteger)nums
                      Block:(void(^)(NSString *msg,NSArray * array,NSArray * arrayURL))block;



/**
 导师列表
 
 @param page
 @param nums
 @param block
 */
+(void)requestApiTeacherPage:(NSInteger)page
                        nums:(NSInteger)nums
                       Block:(void(^)(NSString *msg,NSArray * array))block;



/**
 首页数据
 
 @param tag
 @param page
 @param nums
 @param block
 */
+(void)requestApiHomeDataTag:(NSInteger)tag
                        page:(NSInteger)page
                        nums:(NSInteger)nums
                       Block:(void(^)(NSString *msg,NSArray * array))block;



/**
 获取报名人数
 
 @param block
 */
+ (void)requestApiConfigureEnrollsBlock:(void(^)(NSString *msg,NSNumber * total))block;



/**
 报名

 @param mobile
 @param full_name
 @param idcard
 @param nickname
 @param vcode
 @param teacher_id
 @param block
 */
+(void)requestApiRegisterSignupMobile:(NSString *)mobile
                            full_name:(NSString *)full_name
                               idcard:(NSString *)idcard
                            nickname:(NSString *)nickname
                                vcode:(NSString *)vcode
                           teacher_id:(NSString *)teacher_id
                                Block:(void(^)(NSString *msg,NSString * html5_jump_url))block;



/**
 用户信息

 @param block
 */
+ (void)requestApiUserInfoBlock:(void(^)(NSString *msg,UserModel * model))block;



/**
 选择区域

 @param block
 */
+(void)requestApiAreaBlock:(void(^)(NSString *msg,NSArray * array))block;



/**
 导师详情

 @param Id
 @param block
 */
+(void)requestApiTeacherId:(NSString *)Id
                       Block:(void(^)(NSString *msg,TeacherIndexModel * indexModel))block;



/**
 立即报名文字信息

 @param block 
 */
+ (void)requestApiConfigutrSignupFormTipsBlock:(void(^)(NSString *msg,ConfigSignupFormTipsModel * indexModel))block;

@end
